package com.mall.service;

import com.mall.common.ServerResponse;
import com.mall.pojo.MmallUser;

public interface IUserService {
	
	public MmallUser getUser(int id);
	
	public ServerResponse<MmallUser> login(String username, String password);

	public ServerResponse<String> register(MmallUser user);
	
	public ServerResponse<String> checkValid(String str, String type );

	public ServerResponse<String> selectQuestion(String username);

	public ServerResponse<String> checkAnswer(String username, String question, String answer);

	public ServerResponse<String> resetPassword(String username, String newPassword, String token);

	public ServerResponse<String> loginResetPassword(String oldPassword, String newPassword, MmallUser user);
 
	public ServerResponse<MmallUser> updateInformation(MmallUser user);

	public ServerResponse<MmallUser> getInformation(Integer id);
	 
	public ServerResponse checkAdminRole(MmallUser user);
}
